import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
import path from 'path';
import { fileURLToPath } from 'url';

const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const pathResolve = pathUrl => path.join(__dirname, pathUrl)

export default defineConfig({
  plugins: [react()],
  resolve: {
    alias: {
      "@@": pathResolve("."),
      "@": pathResolve("src"),
      "@assets": pathResolve("src/assets"),
      "@components": pathResolve("src/components"),
      "@pages": pathResolve("src/pages"),
      "@utils": pathResolve("src/utils")
    },
  },
})
